
#ifndef __GAUSSIAN_MIXTURE_VIEWER_H_
#define __GAUSSIAN_MIXTURE_VIEWER_H_

#include <vtkVersion.h>
#include <vtkRenderer.h>
#include <vtkRenderWindowInteractor.h>
#include <vtkRenderWindow.h>
#include <vtkSmartPointer.h>
#include <vtkChartXY.h>
#include <vtkTable.h>
#include <vtkPlot.h>
#include <vtkFloatArray.h>
#include <vtkContextView.h>
#include <vtkContextScene.h>
#include <vtkPen.h>
#include <vector>
#include "Chart.h"

using namespace std;

// TODO: make it inherit from FunctionChart
class GaussianMixtureChart : public Chart
{
	vector<double*> _means;
	vector<double> _variances;
	vector<int> _used_gaussian;

	void _store_gaussian(double *mean, double variance, int used_gaussian);

	public:

		GaussianMixtureChart(int dim, double **limits, int num_slices = 500);
		virtual ~GaussianMixtureChart();
		void AddGaussian(double *mean, double variance, int used = 0);
		virtual vtkSmartPointer<vtkChartXY> BuildChart();
};

#endif
